Imaging processes often involve transformation of regions within the image based on “what is contained” in other parts of the image outside of those regions. In one example, the region defines a “hole” in the image that is then filled based on color values of pixels outside of the region in an image processing technique referred to as “hole filling.” In another example, the region defines a corrupted portion of the image which is repaired based on other portions of the image in an image processing technique referred to as “image healing.” A variety of other examples are also based on similar techniques, such as image restoration and other image editing techniques.
As part of these image editing techniques, pixels within the region are first initialized using color estimates. Processing performed as part of the image editing operation then begins based on these estimated colors. Accordingly, accuracy of these image editing techniques is strongly influenced on the accuracy of the color estimates.
Conventional techniques used to arrive at color estimates rely on a nearest neighbor technique. To do so, a pixel within the region is initialized to a color value based on an adjacent pixel (e.g., nearest neighbor) that is outside of the region. This estimate, however, often fails to support a realistic result. This is typically caused by differences in semantic regions between the pixel being estimated and a pixel that serves as a basis for this estimate. For example, a pixel within the region may in fact represent a dog, but the nearest neighbor pixel outside of the region represents a tree. Because of this, artifacts may be generated within the region based on the conventional techniques which depart from user expectations and realism in the image.